﻿@model ContactVendorModel
@using Nop.Web.Models.Common;
@{
    Layout = "~/Views/Shared/_ColumnsTwo.cshtml";

    //title
    Html.AddTitleParts(T("PageTitle.ContactVendor", Model.VendorName).Text);
}
<div class="panel panel-default form-panel">
    <div class="panel-heading">
        <h3>@T("PageTitle.ContactVendor", Model.VendorName)</h3>
    </div>
    <div class="panel-body">
        @Html.Widget("contactvendor_top")
        @if (Model.SuccessfullySent)
        {
            <div class="result">
                @Model.Result
            </div>
        }
        else
        {
            using (Html.BeginForm())
            {
                <div class="message-error">
                    @Html.ValidationSummary(true)
                </div>
                <div class="form-fields">
                    <div class="inputs-left">
                        <div class="form-group row">
                            @Html.LabelFor(model => model.FullName, new { @class = "col-md-2 control-label" }, ":")
                            <div class="col-md-6">
                                @Html.TextBoxFor(model => model.FullName, new { @class = "form-control", placeholder = T("ContactUs.FullName.Hint") })
                            </div>
                            <div class="col-md-4">
                                @Html.ValidationMessageFor(model => model.FullName)
                            </div>
                        </div>
                        <div class="form-group row">
                            @Html.LabelFor(model => model.Email, new { @class = "col-md-2 control-label" }, ":")
                            <div class="col-md-6">
                                @Html.TextBoxFor(model => model.Email, new { @class = "form-control", placeholder = T("ContactUs.Email.Hint") })
                            </div>
                            <div class="col-md-4">
                                @Html.ValidationMessageFor(model => model.Email)
                            </div>
                        </div>
                        @if (Model.DisplayCaptcha)
                        {
                            <div class="form-group row">
                                <div class="col-md-6 col-md-offset-2">
                                    <div class="left-to-right">
                                        @Html.Raw(Html.GenerateCaptcha())
                                    </div>
                                </div>
                            </div>
                        }
                    </div>
                    <div class="form-group row">
                        @Html.LabelFor(model => model.Enquiry, new { @class = "col-md-2 control-label" }, ":")
                        <div class="col-md-6">
                            @Html.TextAreaFor(model => model.Enquiry, new { @class = "enquiry form-control", placeholder = T("ContactUs.Enquiry.Hint") })
                        </div>
                        <div class="col-md-4">
                            @Html.ValidationMessageFor(model => model.Enquiry)
                        </div>
                    </div>
                </div>
                <div class="buttons">
                    <input type="submit" name="send-email" class="button-1 register-next-step-button btn btn-default" value="@T("ContactUs.Button")" />
                </div>
            }
        }
        @Html.Widget("contactvendor_bottom")
    </div>
</div>
